#include "defines.h"
#include "debug_view.h"
#include "ui_debug_view.h"
#include <QListWidgetItem>

debug_view::debug_view(QWidget *parent) :
    QWidget(parent),
    ui(new Ui::debug_view)
{
    ui->setupUi(this);
}

debug_view::~debug_view()
{
    delete ui;
}

void debug_view::on_listWidget_doubleClicked(const QModelIndex &index)
{
    int i = index.row();
    int j = 0;
    switch(i){
    case 0:
        j = SIGN_IN_VIEW;
        break;
    case 1:
        j = STUDENT_LIST_VIEW;
        break;
    case 2:
        j = STUDENT_VIEW;
        break;
    case 3:
        j = TEST_INFO_VIEW;
        break;
    case 4:
        j = COURSE_VIEW;
        break;
    case 5:
        j = TEST_LIST_VIEW;
        break;
    case 6:
        j = TEST_VIEW;
        break;
    }
    emit(changeScene((ViewsEnum)j));
}
